/** 显示区高度 **/

const innerHeight = {
    data() {
        return {
            innerHeight: 0
        }
    },
    methods: {
        listenResize() {
            this.innerHeight = window.innerHeight
        }
    },
    mounted() {
        this.innerHeight = window.innerHeight
        window.addEventListener('resize', this.listenResize)
    },
    beforeDestroy() {
        window.removeEventListener('resize', this.listenResize)
    }
}

export default innerHeight
